{include file="public/header" /}
<body>
<div class="x-body layui-anim">
    <form class="layui-form" id="form" action="{:url('save')}">
        <input type="hidden" id="id" name="id" value="{$Request.param.id}">
        {include file="public/arguments" /}
        <div class="layui-form-item">
            <label class="layui-form-label">名称</label>
            <div class="layui-input-block">
                <input type="text" name="title" lay-verify="required" lay-reqtext="请填写名称" placeholder="请填写名称" class="layui-input" value="{$info?$info.title:''}"/>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">地址 </label>
            <div class="layui-inline sunSelect" data-url="{:url('order/getArea')}" data-value="code" data-name="title">
                <div class="layui-input-inline">
                    <select name="province" data-name="省" data-level="1" data-id="{$info?$info.province:''}" lay-filter="sunSelect"></select>
                </div>
                <div class="layui-input-inline">
                    <select name="city" data-name="市" data-level="2" data-id="{$info?$info.city:''}" lay-filter="sunSelect"></select>
                </div>
                <div class="layui-input-inline">
                    <select name="district" data-name="区/县" data-level="3" data-id="{$info?$info.district:''}" lay-filter="sunSelect"></select>
                </div>
                <div class="layui-input-inline">
                    <select name="town" data-name="街道" data-level="4" data-id="{$info?$info.town:''}" lay-filter="sunSelect"></select>
                </div>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">详细地址</label>
            <div class="layui-input-block">
                <input type="text" name="details" lay-verify="required" lay-reqtext="请填写详细地址" placeholder="请填写详细地址" class="layui-input" value="{$info?$info.details:''}"/>
            </div>
        </div>


       {include file="form/items/img" type='' /}


        <div class="layui-form-item">
            <label class="layui-form-label">排序</label>
            <div class="layui-input-inline">
                <input type="text" name="sort" autocomplete="off" placeholder="请输入排序，越小越靠前" class="layui-input"
                       value="{$info?$info.sort:''}">
            </div>
        </div>

        <div class="layui-form-item layui-form-text">
            <label class="layui-form-label">详情</label>
            <div class="layui-input-block">
                <div data-filed="content" id="editor—wrapper" class="wang-editor editor—wrapper"
                     data-value='<?php echo isset($info)?$info['content']:"";?>'>
                <input type="hidden" class="editor—content" name="content" value=''/>
                <div class="toolbar-container" id="toolbar-container-content"><!-- 工具栏 --></div>
                <div class="editor-container" id="editor-container-content"><!-- 编辑器 --></div>
            </div>
        </div>
</div>

        <div class="layui-form-item" style="text-align: center;">
            <button class="layui-btn" lay-filter="save" lay-submit formObj="#form">保存</button>
        </div>

    </form>
</div>
</body>
{include file="public/footer" /}

</html>